package goover.unit06;

public class RunnableDemo01 {
    public static void main(String[] args){
        Thread t1 = new Thread(new Thread02(),"t1");
        t1.start();
        Thread t2 = new Thread(new Thread02(),"t2");
        t2.start();
    }
}
class Thread02 implements Runnable{
    @Override
    public void run() {
        int i = 0;
        while(i++ < 5){
            System.out.println(Thread.currentThread().getName());
        }
    }
}